package com.atung.parking.request.save;

import com.atung.parking.enums.MessageType;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;

import javax.validation.constraints.NotBlank;
import javax.validation.constraints.Pattern;
import java.io.Serializable;
import java.math.BigDecimal;

/**
 * @author Administrator
 */
@Data
public class SaveOrUpdateMessageRequest implements Serializable {
    @ApiModelProperty("消息编号")
    private Long id;
    @ApiModelProperty("消息类型")
    private MessageType messageType;
    @ApiModelProperty("停车场名称")
    @NotBlank(message = "停车场名称不能为空")
    private String parkingIotName;
    @ApiModelProperty("预估价格")
    private BigDecimal price;
    @ApiModelProperty("您的称呼")
    @NotBlank(message = "您的称呼不能为空")
    private String contactName;
    @ApiModelProperty("是否有充电桩（0无1有）")
    private Integer hasChargingPile;
    @ApiModelProperty("车位图片")
    private String parkingSpaceImage;
    @ApiModelProperty("车位编号")
    private String parkingSpaceNumber;

    @ApiModelProperty("车位描述")
    @NotBlank(message = "车位描述不能为空")
    private String parkingSpaceDesc;
    @ApiModelProperty("联系电话")
    @NotBlank(message = "联系不能为空")
    @Pattern(regexp = "^1[3-9]\\d{9}$", message = "无效的手机号")
    private String contactPhone;
}
